#ifndef MotorJoystick_h
#define MotorJoystick_h

#include "arduinomega/Wire/Wire.h"
#include "arduinomega/WProgram.h"
#include <stdio.h>

#define MAXBAUDRATE 38400

#define MAX_POWER 1024
#define FULL_DUTY 255
#define HALF_DUTY 128
#define OFF_DUTY 0

const int ENABLE_RIGHT_MOTOR_PIN = 6; // enable pin
const int ENABLE_LEFT_MOTOR_PIN = 7; // enable pin

const int LEFT_MOTOR_CONTROL_PIN_1 = 22; //second bit of the right motor
const int LEFT_MOTOR_CONTROL_PIN_2 = 23; //second bit of the right motor
const int RIGHT_MOTOR_CONTROL_PIN_1 = 24; //second bit of the right motor
const int RIGHT_MOTOR_CONTROL_PIN_2 = 25; //second bit of the right motor
const int SERVO_JOYSTICK_POWER_PIN = 26;

const int receivePin = 0;
const int transmitPin = 1;

const int LEFT_MOTOR_PIN = 0;
const int RIGHT_MOTOR_PIN = 1;
const int SERVO_PIN = 2;

class JoystickMotor
{
public:
	unsigned long rightPotentiometerReading;
	unsigned long leftPotentiometerReading;
	unsigned long servoPotentiometerReading;

	long turn_magnitude;
	long drive_magnitude;

	void setup();
	void loop();
	void printMotorInput();
private:
};

#endif
